namespace PDUConverter
{
    /// <summary>
    /// Message waiting indication. This class is abstract.
    /// </summary>
    public abstract class MessageWaitingIndication : DataCodingScheme
    {
        private bool bit2;

        /// <summary>
        /// Initializes a new instance of the class.
        /// </summary>
        /// <param name="dcs">The DCS byte to decode.</param>
        public MessageWaitingIndication(byte dcs) : base(dcs)
        {
            IndicationType = (byte) (dcs & 3);
            bit2 = (dcs & 4) > 0;
            IndicationActive = (dcs & 8) > 0;
        }

        /// <summary>
        /// Gets if the indication should be set active.
        /// </summary>
        /// <remarks>If true, the indication should be set active, if false, the indication should be set inactive.</remarks>
        public bool IndicationActive { get; private set; }

        /// <summary>
        /// Gets the indication type, how the indication should be shown.
        /// </summary>
        public byte IndicationType { get; private set; }
    }
}